package com.zhuang.chapter07.work01;

public class SalesEmployee extends Employee {
	// 月销售额
	private int MonthVal;
	// 提成率
	private double decrease;

	public SalesEmployee(String name, int month, int monthVal, double decrease) {
		super(name, month);
		MonthVal = monthVal;
		this.decrease = decrease;
	}

	public int getMonthVal() {
		return MonthVal;
	}

	public void setMonthVal(int monthVal) {
		MonthVal = monthVal;
	}

	public double getDecrease() {
		return decrease;
	}

	public void setDecrease(double decrease) {
		this.decrease = decrease;
	}

	public int getSalary(int month) {
		return (int) (MonthVal * decrease + super.getSalary(month));
	}
}
